package com.gxa.utils;
/**
 * 通过员工工龄计算员工级别
 */
public class EmployeeGrade {
    /**
     * A(0-1) 2A(2-4) 3A(5-8)  4A(9-无上限)
     * @param gongLin    员工工龄
     * @return           返回一个string类型
     */
    public static String getGrade(int gongLin){
        int grade = 0;
        String jiBie = null;
        if ( gongLin == 0) {
            jiBie = "暂无";
        }else if (gongLin == 1) {
            jiBie = "A";
        }else if (gongLin < 5) {
            grade = 2;
            jiBie = grade + "A";
        }else if (gongLin < 9) {
            grade = 3;
            jiBie = grade + "A";
        }else {
            grade = 4;
            jiBie = grade + "A";
        }
        return jiBie;
    }
}
